package com.itheima.test4;

public class Test {

    public static void main(String[] args) {
        Fu fu = new Fu() {
            @Override
            public void sing() {
                System.out.println("来一首把");
            }
        };
        fu.sing();
       new Singger() {
            @Override
            public void sing() {
                System.out.println("不来");
            }
        }.sing();
        Student student = new Student();
        student.study();
        new Student(){
            @Override
            public void study() {

                System.out.println("我只想挣钱");
            }
        }.study();
   new Singger() {
            @Override
            public void sing() {

            }
        };

    }
}


abstract  class Fu{
    public abstract  void sing();
}

interface  Singger{
    void sing();
}

 class Student{

    public void study(){
        System.out.println("好好学习天天向上");
    }
}